<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <!-- 引入element-ui样式 -->
    <link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
    <script src="https://cdn.staticfile.org/vue/2.2.2/vue.min.js"></script>
    <!-- 引入element-ui组件库 -->
    <script src="https://unpkg.com/element-ui/lib/index.js"></script>
    <title>v-html</title>
</head>
<body>
<div id="app">
    <p v-html="name">我的名字：</p>
    <p v-html="age">我的年龄：</p>
    <p v-html="address">我住在：</p>
    <!--与插值语法的区别-->
    <p>---与插值语法的区别---</p>
    <p>我的名字：{{name}}</p>
    <p>我的年龄：{{age}}</p>
    <p>我住在：{{address}}</p>
</div>
<script>
    Vue.config.devtools = true
    const vm = new Vue({
        el:'#app',
        data:{
            name:'彭于晏',
            age:18,
            address:'<h3><a href=javascript:location.href="http://www.baidu.com">查询</a></h3>'
        },
    })
</script>
</body>

</html>



